package top.itbbn.otaifs;

public class OtaifsReqStatus {
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    private String name;

    public String getPeroid() {
        return peroid;
    }

    public void setPeroid(String peroid) {
        this.peroid = peroid;
    }

    private String peroid;
    public boolean isFihish;
    public long start;

    public long end;

    public long timeuse;

    public void setStart() {
        isFihish = false;
        start = System.currentTimeMillis();
    }



    public void setEnd() {
        isFihish = true;
        end = System.currentTimeMillis();
        timeuse = (end - start);
    }

    /**
     * 获取当前已使用时间
     *
     * @return
     */
    public long getCurrentTimeUsed() {
        long current = System.currentTimeMillis();
        return current - start;
    }

    public OtaifsReqStatus(String statusName) {
        setPeroid("");
        setName(statusName);
        isFihish = false;
        start = System.currentTimeMillis();
    }


    public OtaifsReqStatus() {
        this("未命名");

    }


}
